#!/bin/sh

range=$1
input=$2
output=$3

hadoop fs -conf ../../conf/rtree.xml -rmr tmp
hadoop jar ../../HyDB-0.5.jar hydb.spatialdb.rtree.EntryStatistics2 \
	-conf ../../conf/rtree.xml -Dhydb.rtree.pack.range=$range $input tmp
hadoop fs -conf ../../conf/rtree.xml -get tmp/part-r-00000 $output
